--- sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vfsops.c.orig
+++ sys/contrib/openzfs/module/os/freebsd/zfs/zfs_vfsops.c
@@ -1845,7 +1845,8 @@
 		return (SET_ERROR(EINVAL));
 	}
 
-	if (fidp->fid_len == LONG_FID_LEN && (fid_gen > 1 || setgen != 0)) {
+	if (fidp->fid_len == LONG_FID_LEN && setgen != 0) {
+		ZFS_EXIT(zfsvfs);
 		dprintf("snapdir fid: fid_gen (%llu) and setgen (%llu)\n",
 		    (u_longlong_t)fid_gen, (u_longlong_t)setgen);
 		return (SET_ERROR(EINVAL));
